#pragma once

#include <OGRE\/Ogre.h>
#include <QThread>

class MyObject :  public QThread
{
public:
	MyObject(void);
	~MyObject(void);
	
    void run();

	Ogre::Entity* getEntity();
	Ogre::SceneNode* getSceneNode();

	void initEntity(Ogre::Entity* ent);
	void initSceneNode(Ogre::SceneNode* sN);

	void setPosition();
	void setOrientation();

	void setPosition(Ogre::Vector3 pos);
	void setOrientation(Ogre::Quaternion rot);
	void setMass(float m);
	void setMaterial(const char what[]);
	

	void move(float x, float y, float z);

	Ogre::Vector3 getPosition();
	Ogre::Quaternion getOrientation();
	Ogre::Vector3 getHalfExtents();
	Ogre::AxisAlignedBox* getBoundingBox();
	float getMass();

private:
	Ogre::Entity *mEntity;
	Ogre::SceneNode* mSceneNode;

	Ogre::Vector3 mPosition;
	Ogre::Quaternion mRotation;
	
	Ogre::Vector3 halfExtents;
	float mass;
	
	Ogre::AxisAlignedBox *boundingBox;
	
	Ogre::MaterialPtr material;
	
    double speedVector[3];
	
};

